<template>
  <div class="home">
      <h3>num:{{num}}</h3>
      <h3>double:{{double}}</h3>
    <button @click="add">增加</button>
  </div>
</template>

<script>
export default {
  name: 'Home',
  data(){
    return{
      num:1
    }
  },
  computed:{
    double(){
      return this.num*2;
    }
  },
  methods:{
    add(){
      this.num++
    }
  },
  components: {

  }
}
</script>
